package com.tca.spring.framework.learning.ioc;

import com.tca.spring.framework.learning.ioc.circulardependency.A;
import com.tca.spring.framework.learning.ioc.circulardependency.B;
import com.tca.spring.framework.learning.ioc.config.CircularDependencyConfiguration;
import org.springframework.context.ApplicationContext;
import org.springframework.context.annotation.AnnotationConfigApplicationContext;

/**
 * @author zhoua
 * @Date 2021/5/2
 */
public class SpringCircularDependencyAnnotationStarter {

    public static void main(String[] args) {
        ApplicationContext applicationContext = new AnnotationConfigApplicationContext(CircularDependencyConfiguration.class);
        A a = applicationContext.getBean(A.class);
        B b = applicationContext.getBean(B.class);
    }
}
